package com.wry.cloud.controller;

import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.client.RestTemplate;

import javax.annotation.Resource;

/**
 * <h1>  <h1>
 *
 * @author 魏如元
 * @since 2022/9/6
 */
@RestController
@Slf4j
@RequestMapping("order-zk")
public class OrderZk1Controller {

    @Resource
    private RestTemplate restTemplate;

    @Value("${payment.url}")
    private String INVOKE_URL;

    @GetMapping
    public String paymentInfo(){
        return restTemplate.getForObject(INVOKE_URL+"/payment-zk",String.class);
    }
}
